<!--
To change this template, choose Tools | Templates
and open the template in the editor.
-->
<!DOCTYPE html>
<html>
    <head>
        <title></title>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/prototype/1.7.0.0/prototype.js"></script>
           
<script type="text/javascript">
    var limitResults=10;
    var i=0;
    var c=0;
    function simulate(){
        console.log('asdfa');
         setInterval(function()
         {
            for(var b=0;b<100;b++){
                if(i!=10000){
                    $('test1').innerHTML+=i;
                    i++;
                }  
            }
         },10);

    }
    function simulate2(){
                setInterval(function()
         {
            if(c!=10000){
                $('test2').innerHTML+=c;
                c++;
            }  
         },10);  
    }
    
        </script>
    </head>
    <body>
        <input type="button" onclick="simulate()" value="simulate1"/><br>
        <input type="button" onclick="simulate2()" value="simulate2"/><br>
        <div style="width:300px;float:left; display:block" id="test1">&nbsp;</div><br/>
        <div style="width:300px;float:left;" id="test2">&nbsp;</div>
    </body>
</html>
